package com.mida.app.report.service;


import com.mida.app.report.vo.request.ExamsInfoVo;
import com.mida.app.report.vo.request.PatientPageInfoVo;
import com.mida.app.report.vo.request.RegistrationListCompleteInfoVo;
import com.mida.app.report.vo.request.SoidMapNameVo;
import com.mida.bms.requestform.dto.RequestPageInfoDto;
import com.mida.bms.requestform.dto.ServiceInstanceInfoDto;
import org.jetbrains.annotations.NotNull;

import java.math.BigDecimal;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;

public interface RequestFormUtilSvc {
    Map<BigDecimal, String> changeServiceInstanceNameSetMap(Set<BigDecimal> msdServiceInstanceSoids);

    Map<BigDecimal, String> changeBusinessNameSetToMap(Set<BigDecimal> businessUnitSoids);

    Map<BigDecimal, String> changeDataSetSoidNameSetToMap(Set<BigDecimal> dataSetSoids);

    Map<BigDecimal, String> changeRequestDoctorSoidNameSetToMap(Set<BigDecimal> requestDoctorSoids);

    @NotNull
    List<HashSet<BigDecimal>> changeSoidsMapToSets(Map<BigDecimal, List<ServiceInstanceInfoDto>> serviceInstanceMap);

    void extracted(List<RequestPageInfoDto> requestPageInfos,
                   Map<String, RegistrationListCompleteInfoVo> records,
                   Map<BigDecimal, PatientPageInfoVo> personDetailInfosMap,
                   Map<BigDecimal, List<ServiceInstanceInfoDto>> serviceInstanceMap,
                   Map<BigDecimal, String> serviceInstanceNameMap,
                   Map<BigDecimal, String> businessNameMap,
                   Map<BigDecimal, String> dataSetSoidNameMap,
                   Map<BigDecimal, String> requestDoctorSoidNameMap);

    void dealExamInfo(Map<BigDecimal, List<ServiceInstanceInfoDto>> serviceInstanceMap,
                      RequestPageInfoDto requestPageInfo,
                      ExamsInfoVo examsInfoVo,
                      Map<BigDecimal, String> businessNameMap,
                      Map<BigDecimal, String> dataSetSoidNameMap,
                      Map<BigDecimal, String> serviceInstanceNameMap);

    @NotNull
    String apendNameStringFromSet(HashSet<String> nameStringSet);

    String splitJointString(String methods, HashSet<String> methodsSet);

    String cutOffLastChar(String methodNames);

    void addStringToSet(String part, HashSet<String>... set);

    /**
     * 单个查询soid对应中文名称并封装到list
     * @param SoidMapNameVos
     * @param soid
     * @return
     */
    @Deprecated
    String setSoidMapName(List<SoidMapNameVo> SoidMapNameVos, BigDecimal soid);

    @NotNull
    Map<BigDecimal, List<ServiceInstanceInfoDto>> changeServiceInstancesToMap(List<RequestPageInfoDto> requestPageInfos);

    @NotNull
    Map<BigDecimal, PatientPageInfoVo> queryPatientInfoVosToMap(List<RequestPageInfoDto> requestPageInfos);
}
